﻿<!--
(c) Copyright Cory Plotts.
This source is subject to the Microsoft Public License (Ms-PL).
Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details.
All other rights reserved.
-->
<Application
	x:Class="Snoop.App"
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	StartupUri="AppChooser.xaml"
	Exit="Application_Exit"
>
	<Application.Resources>
		<ResourceDictionary>
			<ResourceDictionary.MergedDictionaries>
				<ResourceDictionary Source="Icons.xaml"/>
				<ResourceDictionary Source="Simple Styles.xaml"/>
			</ResourceDictionary.MergedDictionaries>

			<!-- appChooserButtonStyle -->
			<Style x:Key="appChooserButtonStyle" TargetType="{x:Type Button}">
				<Setter Property="FocusVisualStyle">
					<Setter.Value>
						<Style>
							<Setter Property="Control.Template">
								<Setter.Value>
									<ControlTemplate>
										<Rectangle
											Margin="3"
											Stroke="Black"
											StrokeThickness="1"
											StrokeDashArray="1 2"
											SnapsToDevicePixels="True"
										/>
									</ControlTemplate>
								</Setter.Value>
							</Setter>
						</Style>
					</Setter.Value>
				</Setter>
				<Setter Property="Background" Value="{DynamicResource MetalGrad}"/>
				<Setter Property="BorderBrush" Value="{DynamicResource DarkBlue}"/>
				<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
				<Setter Property="HorizontalContentAlignment" Value="Center"/>
				<Setter Property="VerticalContentAlignment" Value="Center"/>
				<Setter Property="Template">
					<Setter.Value>
						<ControlTemplate TargetType="{x:Type ButtonBase}">
							<Grid>
								<Border
									x:Name="border"
									Background="{TemplateBinding Background}"
									BorderBrush="{TemplateBinding BorderBrush}"
									BorderThickness="1,1,1,1"
									CornerRadius="4,4,4,4"
								/>
								<ContentPresenter
									x:Name="contentPresenter"
									Margin="2,2,2,2"
								/>
							</Grid>
							<ControlTemplate.Triggers>
								<Trigger Property="IsEnabled" Value="False">
									<Setter Property="Opacity" TargetName="contentPresenter" Value="0.5"/>
									<Setter Property="Opacity" TargetName="border" Value="0.6"/>
								</Trigger>
								<Trigger Property="IsMouseOver" Value="True">
									<Setter Property="Opacity" TargetName="border" Value="1"/>
									<Setter Property="Background" TargetName="border" Value="{DynamicResource mouseOverBackgroundBrush}"/>
								</Trigger>
							</ControlTemplate.Triggers>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>

			<!-- appChooserMinimizeCloseButtonStyle -->
			<Style x:Key="appChooserMinimizeCloseButtonStyle" TargetType="{x:Type Button}" BasedOn="{StaticResource appChooserButtonStyle}">
				<Setter Property="Background" Value="#FF5B0000"/>
				<Setter Property="Foreground" Value="White"/>
				<Style.Triggers>
					<Trigger Property="IsMouseOver" Value="True">
						<Setter Property="Foreground" Value="{DynamicResource DeepBlueColorBrush}"/>
					</Trigger>
				</Style.Triggers>
			</Style>
		</ResourceDictionary>
	</Application.Resources>
</Application>
